a = open('a.txt', 'r', encoding='utf-8')
aTxt = a.read()  # 拿到a文件的内容
a.close()
b = open('b.txt', 'r', encoding='utf-8')
bTxt = b.read()  # 拿到b文件的内容
b.close()
ctxt = aTxt + bTxt  # 把a和b的值合并
c = open('c.txt', 'w', encoding='utf-8')
c.write(ctxt)
c.close()
